The vive_3dsp_dopplersource structure represents the doppler effect of a moving audio source.
More...
#include <vive_3dsp_api/doppler_source.h>
|
(Note that these are not member functions.)
|
| vive_3dsp_dopplersource * | vive_3dsp_dopplersource_create_object (vive_3dsp_context *api, VIVE_3DSP_CHANNELTYPE type, int sampleRate) |
| |
| VIVE_3DSP_API_STATUS | vive_3dsp_dopplersource_destroy_object (vive_3dsp_context *api, vive_3dsp_dopplersource *src) |
| |
| VIVE_3DSP_API_STATUS | vive_3dsp_dopplersource_set_buffer (vive_3dsp_context *api, vive_3dsp_dopplersource *src, float *data, unsigned int size) |
| |
| VIVE_3DSP_API_STATUS | vive_3dsp_dopplersource_set_position (vive_3dsp_context *api, vive_3dsp_dopplersource *src, VIVE_3DSP_Vector3 pos) |
| |
| VIVE_3DSP_API_STATUS | vive_3dsp_dopplersource_set_order (vive_3dsp_context *api, vive_3dsp_dopplersource *src, int order) |
| |
| VIVE_3DSP_API_STATUS | vive_3dsp_dopplersource_process (vive_3dsp_context *api, vive_3dsp_dopplersource *src, float *out_buffer, int sampleLength) |
| |
The vive_3dsp_dopplersource structure represents the doppler effect of a moving audio source.
◆ vive_3dsp_dopplersource_create_object()
Create a audio source object specifically for doppler effect.
- Parameters
-
| api | The audio engine object. |
| type | Input channel type. CHANNELTYPE_MONO for mono and CHANNELTYPE_STEREO for stereo. |
| sampleRate | Sample frequency of the audio source in Hz. |
- Returns
- Doppler source object.
◆ vive_3dsp_dopplersource_destroy_object()
Destroy the specific audio source object.
- Parameters
-
- Returns
- Status code indicating whether or not the operation succeeded.
◆ vive_3dsp_dopplersource_process()
Generate the audio data with doppler effect. Note that the original data should be set by vive_3dsp_dopplersource_set_buffer in advance.
- Parameters
-
- Returns
- Status code indicating whether or not the operation succeeded.
◆ vive_3dsp_dopplersource_set_buffer()
Set the audio clip.
- Parameters
-
- Returns
- Status code indicating whether or not the operation succeeded.
◆ vive_3dsp_dopplersource_set_order()
Set the order of the doppler effect.
- Parameters
-
| api | The audio engine object. |
| src | The audio source object created by vive_3dsp_dopplersource_create_object. |
| order | The doppler effect order. The higher order leads to larger amount of frequency variation. 0 for no effect. |
- Returns
- Status code indicating whether or not the operation succeeded.
◆ vive_3dsp_dopplersource_set_position()
Set the position of the audio source object.
- Parameters
-
- Returns
- Status code indicating whether or not the operation succeeded.
The documentation for this struct was generated from the following file: